package de.lusiardi.webdav.headers;

import java.util.logging.Logger;

public class DestinationHeader implements Header {

    private static final Logger logger = Logger.getLogger(DestinationHeader.class.getCanonicalName());

    public static final String KEY = "Destination";

    private String value;

    public String getKey() {
        return KEY;
    }

    public void setValue(String val) {
        value = val;
        if (!checkValue()) {
            logger.warning(String.format("'%s' is an invalid value for Destination header.", value));
        }
    }

    public String getValue() {
        return value;
    }

    /**
     * <pre> Destination = "Destination" ":" Simple-ref</pre>
     *
     * @return
     */
    public boolean checkValue() {
        return true;
    }
}
